package com.wlyuan.open.remote.converter;

import com.alibaba.fastjson.JSON;
import com.wlyuan.open.remote.message.TrackMessage;
import lombok.var;

/**
 * @author
 * 订单签收消息转化器
 */
public class TrackMessageConverter implements StringMessageConverter<TrackMessage>{

    @Override
    public TrackMessage convert(String source) {
        var message = JSON.parseObject(String.valueOf(JSON.parse(source)));
        source = message.toString();
        return JSON.parseObject(source, TrackMessage.class);
    }
}
